package com.ruoyi.ruoyinetty.entity.request;

import com.ruoyi.ruoyinetty.entity.PackageData;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

@ToString
@NoArgsConstructor
@Data
public class LocationMsg extends PackageData {

    public LocationMsg(PackageData packageData) {
        this();
        this.channel = packageData.getChannel();
        this.checkSum = packageData.getCheckSum();
        this.msgBodyBytes = packageData.getMsgBodyBytes();
        this.msgHeader = packageData.getMsgHeader();
    }

    private LocationInfo locationInfo;


    @Data
    @ToString
    @NoArgsConstructor
    public static class LocationInfo {

        private int warningFlag;

        private int status;

        private int latitude;

        private int longitude;

        private int high;

        private int speed;

        private int direction;

        private String time;

    }
}
